import React, { Component } from 'react'

export default class App extends Component {
  constructor() {
    super()
    
    this.state = {
      color: "purple"
    }
  }
  render() {
    const pStyle = {
      color: "orange",
      textDecoration: "underline"
    }
    return (
      <div>
        <h2 style={{fontSize: '30px', color: 'pink'}}>标题</h2>
        <p style={pStyle}>一段文字描述...</p>
        <span style={{color: this.state.color}}>span标签</span>
      </div>
    )
  }
}
